﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SubstituteSku.aspx.cs" Inherits="WMS6.Web.Configuration.SubstituteSku" meta:resourcekey="Page" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>SubstituteSku</title>
    <link href="../style/zh/1/css.css" type="text/css" rel="Stylesheet" id="mycss" />
    <link href="../Css/style.css" type="text/css" rel="stylesheet" />
    <script src="../Js/jquery.js" type="text/javascript"></script>
    <script src="../Js/jquery.simplemodal.js" type="text/javascript"></script>
    <script src="../Js/util.js" id="js" type="text/javascript"></script>
    <script src="../Js/InitPage.js" type="text/javascript"></script>        
    <script type="text/javascript">
        //初始化页面
        window.onload = function(){
            initDetailPage();
        }
        
        //弹出窗口选择包装
        function selectPack()
        {
            var rtnValue = popModalWindow('../Configuration/PackQuery.aspx?action=txtPack','dialogWidth=800px;dialogHeight=500px;center=yes;resizable=yes;status=no;');
            if(rtnValue != null && rtnValue.toString() != "")
            {
                document.getElementById("txtPack").focus();
                document.getElementById("txtPack").value = rtnValue;
                __doPostBack("txtPack_TextChanged","");
            }
        }
       
       function selectSubPack()
        {
            var rtnValue = popModalWindow('../Configuration/PackQuery.aspx?action=txtSubPack','dialogWidth=800px;dialogHeight=500px;center=yes;resizable=yes;status=no;');
            if(rtnValue != null && rtnValue.toString() != "")
            {
                document.getElementById("txtSubPack").focus();
                document.getElementById("txtSubPack").value = rtnValue;
                __doPostBack("txtSubPack_TextChanged","");
            }
        }
        //弹出替代料对话框
        function selectSubSku()
        {
            var rtnValue = popModalWindow('../Configuration/SKUQuery.aspx?action=txtSubSkuID&ownerID='+escape(document.getElementById("txtOwnerID").value),'dialogWidth=800px;dialogHeight=500px;center=yes;resizable=yes;status=no;');
            if(rtnValue != null && rtnValue.toString() != "") {

                if (document.getElementById("txtSkuID").value != rtnValue) {
                    document.getElementById("txtSubSkuID").focus();
                    document.getElementById("txtSubSkuID").value = rtnValue;  
                    __doPostBack("txtSubSkuID_TextChanged","");
                    
                }
                else {
                    document.getElementById('lblMsg').innerHTML = '<%=GetGlobalMsgResource("F2110_023") %>';
                }
               
            }
        }
        
    </script>
</head>
<body>
    <form id="F2064" runat="server">
    <div>
        <asp:ScriptManager ID="ScriptManager1" runat="server" />
        <div id="div_top">
            <table>
                <tr>
                    <td valign="bottom"><asp:Label ID="lblSubstituteSku" runat="server" 
                            CssClass="label_header" Text="货品替代料" 
                            meta:resourcekey="lblSubstituteSku"></asp:Label></td>
                    <td><asp:Button ID="btnCancel" runat="server" Enabled="False" CssClass="button" Text="<%$Resources:ButtonResource,btnCancel%>" 
                            AccessKey="c" onclick="btnCancel_Click"  /></td>
                    <td><asp:Button ID="btnSave" runat="server" CssClass="button"  Enabled="False" Text="<%$Resources:ButtonResource,btnSave%>" 
                            AccessKey="s" onclick="btnSave_Click" 
                             /></td>
                </tr>
            </table>
        </div>
        
        <div>
            <asp:Label ID="lblMsg" runat="server" CssClass="label_message" 
                meta:resourcekey="lblMsg"></asp:Label>
        </div>
        <div id="div_menu">
            <div style="float: left; width: 8px;">
                <div class="tabL" id="imgL1"></div>
            </div>
            <div class="tabLabelCont tabCur" id="div1">
                <asp:Label ID="one1" runat="server" class="hover" Text="货品替代料" 
                    meta:resourcekey="one1"></asp:Label></div>
            <div style="float: left; margin-right: 2px;">
                <div class="tabR" id="imgR1"></div>
            </div>
        </div>
        
        <div id="div_content">
             <div id="con_one_1" style="display: block;">
                 <table width="540" style="display: block; margin-left: 10px; margin-top: 10px;">
                 <tr>
                         <td width="180">
                             <asp:Label ID="lblOwnerID" runat="server" CssClass="label" Text="货主代码" 
                                 Enabled="False" meta:resourcekey="lblOwnerID"></asp:Label><span class="must_input">*</span>
                         </td>
                         <td width="180">
                             
                             <asp:Label ID="lblSeqNo" runat="server" CssClass="label" Text="序号" 
                                 meta:resourcekey="lblSeqNo" ></asp:Label>
                             
                         </td>
                         <td width="180">
                             <asp:Label ID="lblUdf1" runat="server" CssClass="label" Text="自定义01" 
                                 meta:resourcekey="lblUdf1"></asp:Label>
                         </td>
                     </tr>
                     <tr>
                         <td>
                             <asp:TextBox ID="txtOwnerID" runat="server" CssClass="textbox" MaxLength="30" 
                                 Enabled="False" meta:resourcekey="txtOwnerID"></asp:TextBox>
                         </td>
                         <td>
                             <asp:TextBox ID="txtSeqNo" runat="server" CssClass="textbox" MaxLength="30"   meta:resourcekey="txtSeqNo"></asp:TextBox>
                         </td>
                         <td>
                             <asp:TextBox ID="txtUdf1" runat="server" CssClass="textbox" MaxLength="20" 
                                 meta:resourcekey="txtUdf1"></asp:TextBox>
                         </td>
                     </tr>
                     <tr>
                         <td width="180">
                             <asp:Label ID="lblSkuID" runat="server" CssClass="label" Text="货品代码" 
                                 meta:resourcekey="lblSkuID"></asp:Label><span class="must_input">*</span>
                         </td>
                         <td width="180">
                             
                             <asp:Label ID="lblSubSku" runat="server" CssClass="label" Text="替代料" 
                                 meta:resourcekey="lblSubSku" ></asp:Label>
                             
                         </td>
                         <td width="180">
                             <asp:Label ID="lblUdf2" runat="server" CssClass="label" Text="自定义02" 
                                 meta:resourcekey="lblUdf2"></asp:Label></td>
                     </tr>
                     <tr>
                         <td>
                             <asp:TextBox ID="txtSkuID" runat="server" CssClass="textbox" MaxLength="30" 
                                 Enabled="False" meta:resourcekey="txtSkuID" 
                                 OnTextChanged="txtSkuID_TextChanged"></asp:TextBox>
                         </td>
                         <td>
                             <asp:TextBox ID="txtSubSkuID" runat="server" CssClass="textbox" MaxLength="30"  AutoPostBack="true"
                                 meta:resourcekey="txtSubSkuID" OnTextChanged="txtSubSkuID_TextChanged" ></asp:TextBox><img src="../Images/icon_find.gif" alt="select one item" class="img" onclick="selectSubSku();"/>
                         </td>
                         <td>
                             <asp:TextBox ID="txtUdf2" runat="server" CssClass="textbox" MaxLength="20" 
                                 meta:resourcekey="txtUdf2"></asp:TextBox></td>
                     </tr>
                     <tr>
                         <td width="180">
                             <asp:Label ID="lblPack" runat="server" CssClass="label" Text="包装代码" 
                                 meta:resourcekey="lblPack"></asp:Label>
                         </td>
                         <td width="180"><asp:Label ID="lblSubPack" runat="server" CssClass="label" 
                                 Text="替代包装代码" meta:resourcekey="lblSubPack" ></asp:Label></td>
                         <td width="180"><asp:Label ID="lblUdf3" runat="server" CssClass="label" 
                                 Text="自定义03" meta:resourcekey="lblUdf3"></asp:Label></td>
                     </tr>
                     <tr>
                         <td>
                             <asp:TextBox ID="txtPack" runat="server" CssClass="textbox" MaxLength="30" 
                                 ontextchanged="txtPack_TextChanged" AutoPostBack="true" 
                                 meta:resourcekey="txtPack"></asp:TextBox><%--<img src="../Images/icon_find.gif" alt="select one item" class="img" onclick="selectPack();"/>--%>
                         </td>
                         <td>
                             <asp:TextBox ID="txtSubPack" runat="server" CssClass="textbox" 
                                 MaxLength="30" ontextchanged="txtSubPack_TextChanged" AutoPostBack="true"
                                 meta:resourcekey="txtSubPack" ></asp:TextBox><%--<img src="../Images/icon_find.gif" alt="select one item" class="img" onclick="selectSubPack();"/>--%>
                         </td>
                         <td><asp:TextBox ID="txtUdf3" runat="server" CssClass="textbox" MaxLength="20" 
                                 meta:resourcekey="txtUdf3"></asp:TextBox></td>
                     </tr>
                     <tr>
                         <td width="180">
                             <asp:Label ID="lblUom" runat="server" CssClass="label" Text="计量单位" 
                                 meta:resourcekey="lblUom"></asp:Label>
                         </td>
                         <td width="180">
                             <asp:Label ID="lblSubUom" runat="server" CssClass="label" Text="替代料计量单位" 
                                 meta:resourcekey="lblSubUom"></asp:Label>
                         </td>
                         <td width="180"><asp:Label ID="lblUdf4" runat="server" CssClass="label" 
                                 Text="自定义04" meta:resourcekey="lblUdf4"></asp:Label></td>
                     </tr>
                     <tr>
                         <td>
                             <asp:DropDownList ID="ddlUom" runat="server" CssClass="mediumselectbox" 
                                 meta:resourcekey="ddlUom"></asp:DropDownList>
                         </td>
                         <td>
                             <asp:DropDownList ID="ddlSubUom" runat="server" CssClass="mediumselectbox" 
                                 meta:resourcekey="ddlSubUom"></asp:DropDownList></td>
                         <td><asp:TextBox ID="txtUdf4" runat="server" CssClass="textbox" MaxLength="20" 
                                 meta:resourcekey="txtUdf4"></asp:TextBox></td>
                     </tr>
                     <tr>
                         <td width="180">
                             <asp:Label ID="lblQty" runat="server" CssClass="label" Text="数量" 
                                 meta:resourcekey="lblQty"></asp:Label>
                         </td>
                         <td width="180">
                             <asp:Label ID="lblSubQty" runat="server" CssClass="label" Text="数量" 
                                 meta:resourcekey="lblSubQty"></asp:Label>
                         </td>
                         <td width="180"><asp:Label ID="lblUdf5" runat="server" CssClass="label" 
                                 Text="自定义05" meta:resourcekey="lblUdf5"></asp:Label></td>
                     </tr>
                     <tr>
                         <td>
                             <asp:TextBox ID="txtQty" runat="server" CssClass="textbox" MaxLength="30" 
                                 meta:resourcekey="txtQty"></asp:TextBox>
                         </td>
                         <td>
                             <asp:TextBox ID="txtSubQty" runat="server" CssClass="textbox" 
                                 MaxLength="30" meta:resourcekey="txtSubQty" ></asp:TextBox>
                         </td>
                         <td><asp:TextBox ID="txtUdf5" runat="server" CssClass="textbox" MaxLength="20" 
                                 meta:resourcekey="txtUdf5"></asp:TextBox></td>
                     </tr>
                     <tr>
                         <td width="180">
                             <asp:Label ID="lblSkuMainUomQty" runat="server" CssClass="label" Text="货品主单位数量" 
                                 meta:resourcekey="lblSkuMainUomQty"></asp:Label>
                         </td>
                         <td width="180">
                             <asp:Label ID="lblSubSkuMainSkuQty" runat="server" CssClass="label" 
                                 Text="替代主单位数量" meta:resourcekey="lblSubSkuMainSkuQty"></asp:Label>
                         </td>
                         <td width="180"></td>
                     </tr>
                     <tr>
                         <td>
                             <asp:TextBox ID="txtSkuMainUomQty" runat="server" CssClass="textbox"  Enabled="false"  Text="1.00" 
                                 MaxLength="30"></asp:TextBox>
                         </td>
                         <td>
                             <asp:TextBox ID="txtSubSkuMainSkuQty" runat="server" CssClass="textbox"  Enabled="false"  Text="1.00" 
                                 MaxLength="30" ></asp:TextBox>
                         </td>
                         <td></td>
                     </tr>
                     <tr style="height:10px;">
                        <td></td>
                        <td></td>
                        <td></td>
                     </tr>
                     <tr>
                         <td>
                             <asp:CheckBox ID="chkIsActive" runat="server" CssClass="checkbox" Text="启用" 
                                 Checked="True" meta:resourcekey="chkIsActive" /></td>
                         <td></td>
                         <td></td>
                     </tr>
                 </table>
             </div>
         </div>        
    </div>
    <input type="hidden" id="hdnFrom" runat="server" />
    <input type="hidden" id="hdnType" runat="server" />
    <input type="hidden" id="hdnSubstituteSkuID" runat="server" />
    </form>
</body>
</html>
